//
//  MyorderdetailViewController.m
//  parent
//
//  Created by yanzhen on 15/7/19.
//  Copyright (c) 2015年 ci123. All rights reserved.
//

#import "MyorderdetailViewController.h"
#import "AFAppClient.h"

@interface MyorderdetailViewController ()
@property (weak, nonatomic) IBOutlet UIScrollView *scrollview;

@end

@implementation MyorderdetailViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    self.navigationItem.title = @"订单详情";
    [self CustomBackButton];
    [self initData];
}
-(void)initData
{
    [self showHud:kLoadingData isDim:YES];
    [[AFAppClient sharedManager]getWithURL:[NSString stringWithFormat:@"%@%@",SERVER_URL_NEW,kOrderDetail] withParameters:@{@"oid":@(_oid)} success:^(NSDictionary *responseObject) {
        NSUInteger code = [[responseObject objectForKey:@"code"]integerValue];
        if(code ==0){
            [self showHudComplete:@"订单不存在" success:YES];
        }else{
            [self hideHud2];
            NSDictionary *result = [responseObject objectForKey:@"result"];
        }
    } failure:^(NSError *error) {
        [self showHudComplete:kNoNetwork success:NO];
    }];
}
-(void)viewDidAppear:(BOOL)animated{
    self.scrollview.contentSize = CGSizeMake(APP_SCREEN_WIDTH, 736);
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
